class UsersController < ApplicationController

active_scaffold :user do |config|
    config.columns = [   :login_name, :real_name, :phone_number, :email_address,
                      :password, :photo, :juese]
    config.label = "用户信息管理"
    config.columns[:phone_number].description = "(Format: ###-###-####)"
    config.columns[:phone_number].label = "电话"
    config.columns[:login_name].label = "用户名"
    config.columns[:real_name].label = "真实姓名"
    config.columns[:email_address].label = "Email"
    config.columns[:password].label = "密码"
    config.columns[:juese].label = "角色"
    config.columns[:photo].label = "照片"
   
    
#    config.create.columns.exclude :id
#    config.update.columns.exclude :id
#    
#    config.list.columns.exclude :login_name, :real_name, :password, :phone_number
#    
#    config.subform.columns = [:login_name, :real_name, :password]
#
#    config.list.sorting = {:login_name => 'ASC'}
#
##    config.nested.add_link "Names", [:aliases]
#
#    config.create.columns.exclude(:login_name, :real_name, :phone_number)
    
  end
  
 
  
end
